package com.ddm.entity.webEntity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.time.LocalDateTime;

/**
 * 市场供需信息（根据表功能合理命名，可按需调整）
 *
 * @author 你自己的作者名
 * @since 2025/07/06
 */
@Data
@TableName("market_supply_demand") // 映射数据库表名，根据实际表名调整
@ApiModel(value = "MarketSp对象", description = "市场供需信息实体")
public class MarketSp {

    @ApiModelProperty(value = "主键ID")
    @TableId(value = "id", type = IdType.AUTO)
    private long id;

    @ApiModelProperty(value = "标题")
    @TableField("sd_title")
    private String sdTitle;

    @ApiModelProperty(value = "价格")
    @TableField("sd_price")
    private String sdPrice;

    @ApiModelProperty(value = "数量")
    @TableField("sd_count")
    private String sdCount;

    @ApiModelProperty(value = "链接")
    @TableField("sd_url")
    private String sdUrl;

    @ApiModelProperty(value = "电话")
    @TableField("sd_phone")
    private String sdPhone;

    @ApiModelProperty(value = "发布人")
    @TableField("sd_man")
    private String sdMan;

    @ApiModelProperty(value = "图片")
    @TableField("sd_img")
    private String sdImg;

    @ApiModelProperty(value = "发布日期")
    @TableField("sd_publish_date")
    private LocalDateTime sdPublishDate;

    @ApiModelProperty(value = "用户ID")
    @TableField("userid")
    private long userId;

    @ApiModelProperty(value = "审核状态：null-待审核，1-通过（上架），2-下架，0-未通过")
    @TableField(value = "status", updateStrategy = FieldStrategy.IGNORED)  // 合并属性
    private String status;

    @ApiModelProperty(value = "审核信息")
    @TableField("status_message")
    private String statusMessage;

    @ApiModelProperty(value = "供求信息种类")
    @TableField("sd_type")
    private String sdType;

    @ApiModelProperty(value = "单位")
    @TableField("standard")
    private String standard;

    @ApiModelProperty(value = "摘要")
    @TableField("sd_abstract")
    private String sdAbstract;
}